const http = require('http')

const hostname = '127.0.0.1'
const port = 13817

http.createServer((req, res) => {
	res.writeHead(200, {
		'Content-Type': 'application/json'
	});
	var mArray = ['item1', 'item2', 'array3']
	var mObject = {
		item1: 'item1value',
		item2: 'item2value'
	}
	var json = JSON.stringify({
		code: 0,
		isSuccess: true,
		object: mObject,
		array: mArray
	})

	res.end(json)
}).listen(port, hostname, () => {
	console.log('running at http://' + hostname + ':' + port + '/');
});
console.log('running');